﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="SetupYearForm.aspx.cs"
    Inherits="FBKPI.Forms.SetupYearForm" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
    <script type="text/javascript">
        $(document).ready(function () {

            $("#btn_save").click(function () {
                var param = "?";
                var isActive = 'false';

                $('#form1 td input:checked').each(function () {
                    var $cb = $(this);
                    if ($cb.attr('id') == 'chk_active') {
                        isActive = 'true';
                    }
                });

                param = param + "action=save";
                param = param + "&YearID=" + $("#hfId").val();
                param = param + "&StartYear=" + $('#ddlStartYear option:selected').val();
                param = param + "&EndYear=" + $('#ddlEndYear option:selected').val();
                param = param + "&CurrUser=" + $("#txt_user").val();
                ProcessRequest("SetupYearHandler.ashx" + param, "#divdetail", "#SetupYearTable");
                return false;
            });




            $("#btn_close").click(function () {
                parent.$("#divdetail").dialog("close");
                return false;
            });


        });
    </script>
</head>
<body>
    <form id="form1" runat="server">
    <div id="sectionformarea" class="ui-widget-content padding5px ui-corner-all">
        <table class="dialogTable">
            <tr runat="server" visible="false">
                <td style="padding-right:20px;">
                    Start Year
                </td>
                <td style="padding-right:20px;">
                    :
                </td>
                <td>
                    <asp:DropDownList ID="ddlStartYear" runat="server" Width="100">
                    </asp:DropDownList>
                </td>
            </tr>
            <tr>
                 <td style="padding-right:20px;">
                    Year
                </td>
                 <td style="padding-right:20px;">
                    :
                </td>
                <td>
                    <asp:DropDownList ID="ddlEndYear" runat="server" Width="100">
                    </asp:DropDownList>
                </td>
            </tr>
        </table>
    </div>
    <br />
    <button id="btn_save" class="button save">
        Save
    </button>
    <button id="btn_close" class="button close">
        Close
    </button>
   
    <asp:HiddenField ID="hfId" runat="server" Value="0" />
    </form>
</body>
</html>
